<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" trimDirectiveWhitespaces="true"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<div id="contents">
<c:if test="${ regi eq 'y' }">
	<c:if test="${ isregi eq 'success' }">
		<div class="alert alert-success alert-dismissable">
		  <button type="button" class="close" data-dismiss="alert" aria-hidden="true">&times;</button>
		  <strong>영화 등록 성공!!</strong> 상영정보를 등록해 주세요.<a href="">상영정보 등록</a>
		</div>
	</c:if>
	<c:if test="${ isregi eq 'fail' }">
		<div class="alert alert-danger alert-dismissable">
		  <button type="button" class="close" data-dismiss="alert" aria-hidden="true">&times;</button>
		  <strong>영화 등록 실패!</strong> 영화정보를 다시한번 확인해 주세요.
		</div>
	</c:if>
</c:if>
<form id="movieregi" method="post" enctype="multipart/form-data">
	<fieldset>
		<legend>영화 등록</legend>
		<div id="center">
			<div>
				<label for="title" class="control-label">제목</label>
				<input type="text" class="form-control" id="title" name="title"
				 placeholder="제목" title="제목을 입력하세요" required="required" />
			</div>
			<div id="left">
			<div id="genre">
				<label for="genre" class="control-label">장르</label>
				<input type="text" name="genre1" id="genre1" class="form-control" placeholder="장르" title="장르를 선택하세요" required="required" />
				<input type="text" name="genre2" id="genre2" class="form-control" placeholder="장르" title="장르를 선택하세요" />
				<input type="text" name="genre3" id="genre3" class="form-control" placeholder="장르" title="장르를 선택하세요" />
			</div>			
			<div>
				<label for="director" class="control-label">감독</label>
				<input type="text" class="form-control" id="director" name="director"
					placeholder="감독" title="감독의 이름을 입력하세요" required="required" />
			</div>
			<div>
				<label for="actor" id="actor" class="control-label">배우</label>
				<input type="text" class="form-control" id="actor1" name="actor1"
						placeholder="배우" title="배우의 이름을 입력하세요"  required="required" />
				<input type="text" class="form-control" id="actor2" name="actor2" placeholder="배우" title="배우의 이름을 입력하세요" />
				<input type="text" class="form-control" id="actor3" name="actor3" placeholder="배우" title="배우의 이름을 입력하세요" />
			</div>
			</div>
			<div id="file" class="form-control">	
				<input type="file" id="filechooser" name="poster" placeholder="포스터 이미지 등록" title="포스터 이미지를 선택하세요" />
				<div id="poster">
					
				</div>
			</div>
			<div class="clear">
				<label for="rate" class="control-label">등급</label>
				<select class="form-control" id="rate" name="rate" title="관람등급을 선택하세요" required="required">
					<option>등급 선택</option>
					<option value="1">전체 관람가</option>
					<option value="2">12세 관람가</option>
					<option value="3">15세 관람가</option>
					<option value="4">청소년 관람불가</option>
				</select>
				<label for="runningtime" class="control-label">상영시간</label>
				<input type="text" class="form-control" id="runningtime" name="runningtime"
					placeholder="상영시간" title="상영시간을 입력하세요" required="required" />
				<label for="playdate" class="control-label">개봉일</label>
				<input type="text" id="playdate" class="form-control" name="playdate"
					placeholder="개봉일 선택" title="개봉날짜를 선택하세요" required="required" />
			</div>
			<div class="clear">
				<label for="title" class="control-label">줄거리</label>
				<textarea id="synop" class="form-control" name="synop"
					placeholder="줄거리" title="줄거리 입력하세요"></textarea>
			</div>
			<div id="btn">
				<label class="control-label"></label>
				<button type="submit" class="btn btn-primary">등 록</button>
				<button type="reset" class="btn btn-default">다시입력</button>
			</div>
		</div>
	</fieldset>
</form>
</div>
<script src="js/datepicker.js"></script>
<script src="js/admin-movie-ajax.js"></script>
